// @ts-ignore
/* eslint-disable */
import { request } from '@umijs/max';
const apiPrefix = '/web';

/** GLC实时监控数据 GET /device/glc/lastdata */
export async function lcControllerGetLastData(options?: { [key: string]: any }) {
  return request<API.GlcRealTimeData>(`${apiPrefix}/device/glc/lastdata`, {
    method: 'GET',
    ...(options || {}),
  });
}

/** LC事件数据 分页获取LC事件数据 GET /device/lc/events */
export async function lcControllerGetLcPageEvents(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.lcControllerGetLcPageEventsParams,
  options?: { [key: string]: any },
) {
  return request<API.ApiResultPaginationEventPageData>(`${apiPrefix}/device/lc/events`, {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  });
}

/** LC实时监控数据 GET /device/lc/lastdata */
export async function lcControllerGetLcRealTimeData(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.lcControllerGetLcRealTimeDataParams,
  options?: { [key: string]: any },
) {
  return request<API.LcRealTimeData>(`${apiPrefix}/device/lc/lastdata`, {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  });
}

/** 分页查询 分页查询LC数据 GET /device/lc/list */
export async function lcControllerGetLcPageDatas(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.lcControllerGetLcPageDatasParams,
  options?: { [key: string]: any },
) {
  return request<API.Pagination>(`${apiPrefix}/device/lc/list`, {
    method: 'GET',
    params: {
      ...params,
      page: undefined,
      ...params['page'],
      search: undefined,
      ...params['search'],
    },
    ...(options || {}),
  });
}

/** 电表数据 获取电表数据 GET /device/lc/meter */
export async function lcControllerGetMeterData(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.lcControllerGetMeterDataParams,
  options?: { [key: string]: any },
) {
  return request<API.MeterPageData>(`${apiPrefix}/device/lc/meter`, {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  });
}

/** 电表设备列表 GET /device/lc/meters */
export async function lcControllerGetMeters(options?: { [key: string]: any }) {
  return request<API.MeterVo[]>(`${apiPrefix}/device/lc/meters`, {
    method: 'GET',
    ...(options || {}),
  });
}
